package logic;

import java.util.ArrayList;

public class EndMatch extends Exception {
	/**
	 * 
	 */
	private static final long serialVersionUID = -1318157677058215547L;
	private Team looser;
	private Team winner;
	private ArrayList<Integer[]> lastTrajectory;
	
	public EndMatch(Team looser, ArrayList<Integer[]> lastTrajectory){
		super("Match ends: Pharoh of team "+looser+" died.");
		this.lastTrajectory = lastTrajectory;
		this.looser = looser;
		if(looser==Team.RED){
			winner = Team.GRAY;
		}else{
			winner = Team.RED;
		}
	}
	
	public Team getLooser(){
		return looser;
	}
	
	public Team getWinner(){
		return winner;
	}
	
	public ArrayList<Integer[]> getTrajectory(){
		return lastTrajectory;
	}

}
